package pers.wensheng.patterns.behavioral_pattern.strategy_pattern.foundation;

import pers.wensheng.patterns.behavioral_pattern.strategy_pattern.foundation.entity.StrategyA;
import pers.wensheng.patterns.behavioral_pattern.strategy_pattern.foundation.entity.StrategyB;

/**
 * 策略模式
 */
public class Client {
    public static void main(String[] args) {
        //春节来了，使用春节促销活动
        SalesMan salesMan = new SalesMan(new StrategyA());
        salesMan.salesManShow();

        //中秋节
        SalesMan salesMan1 = new SalesMan(new StrategyB());
        salesMan1.salesManShow();

    }
}
